home *** CD-ROM | disk | FTP | other *** search
Wrap
Text File | 1996-05-01 | 89.7 KB | 1,676 lines | [ TEXT/MPS ]
; ; File: OCETemplates.a ; ; Contains: Apple Open Collaboration Environment Templates Interfaces. ; ; Version: Technology: AOCE Toolbox 1.02 ; Release: Universal Interfaces 3.0d3 on Copland DR1 ; ; Copyright: © 1984-1996 by Apple Computer, Inc. All rights reserved. ; ; Bugs?: If you find a problem with this file, send the file and version ; information (from above) and the problem description to: ; ; Internet: apple.bugs@applelink.apple.com ; AppleLink: APPLE.BUGS ; ; IF &TYPE('__OCETEMPLATES__') = 'UNDEFINED' THEN __OCETEMPLATES__ SET 1 IF &TYPE('__TYPES__') = 'UNDEFINED' THEN include 'Types.a' ENDIF IF &TYPE('__EVENTS__') = 'UNDEFINED' THEN include 'Events.a' ENDIF IF &TYPE('__OCE__') = 'UNDEFINED' THEN include 'OCE.a' ENDIF IF &TYPE('__OCESTANDARDMAIL__') = 'UNDEFINED' THEN include 'OCEStandardMail.a' ENDIF IF FOR_SYSTEM7_ONLY THEN ; ;*********************************************************************************************** ; ********************************* Template Resource Constants: ********************************* ; *********************************************************************************************** ; ; Current versions of all the different template types: kDETAspectVersion EQU -976 kDETInfoPageVersion EQU -976 kDETKillerVersion EQU -976 kDETForwarderVersion EQU -976 kDETFileTypeVersion EQU -976 ; ; "Normal" separation for template IDs within the file (this is just a suggestion; you can use whatever ; separation you like, so long as two separate templates don't have overlapping resources): ; kDETIDSep EQU 250 ; A few predefined base IDs (again, just suggestions): kDETFirstID EQU 1000 kDETSecondID EQU 1250 kDETThirdID EQU 1500 kDETFourthID EQU 1750 kDETFifthID EQU 2000 ; ; Templates consist of a set of associated resources, at constant offsets from a "base ID" set by the ; signature resource of the template. In the case of aspect templates, most of the resources in the ; template are accessible from the template as property default values. The property number is the same ; as the offset from the base ID of the resource. In describing the resources which make up templates, ; we give the type, the offset, and a description. For aspect templates, the offset is also the property #. ; ; All templates include the following resource fork resources: ; ; Type Offset Description ; ---- ------ ----------- ; 'rstr' kDETTemplateName Contains the name of the template ; ; kDETTemplateName EQU 0 ; ; Aspects, info-pages, and forwarders include the following as well: ; ; Type Offset Description ; ---- ------ ----------- ; 'rstr' kDETRecordType Contains the type of record this applies to ; 'rstr' kDETAttributeType Contains the type of attribute this applies to ; 'detn' kDETAttributeValueTag Contains the tag of the attribute values this applies to ; ; kDETRecordType EQU 1 kDETAttributeType EQU 2 kDETAttributeValueTag EQU 3 ; ************************************ Aspects ; ; In the case of aspects, property numbers and resource id offsets are the same. Therefore, some of the following ; defines are used for resource offsets, some are used for dynamically generated properties, and some are used for ; both (i.e., properties which may be dynamically generated, but if they aren't, then they're taken from the ; resource). Resource types are given in all cases below; even if there is no actual resource (for example in ; the case of kDETAspectName), it indicates the type for the dynamically generated property. A resource type of ; 'rstr' corresponds to a property type of kDETPrTypeString; type 'detn' corresponds to kDETPrTypeNumber; and ; 'detb' corresponds to kDETPrTypeBinary. ; ; Type Offset Description ; ---- ------ ----------- ; 'deta' 0 Identifies the type of resource ; 'detc' kDETCode Is the code resource, if any is used ; 'ICN#' kDETAspectMainBitmap ; 'icl8' kDETAspectMainBitmap ; 'icl4' kDETAspectMainBitmap ; 'ics#' kDETAspectMainBitmap ; 'ics8' kDETAspectMainBitmap ; 'ics4' kDETAspectMainBitmap ; 'sicn' kDETAspectMainBitmap Is the icon suite to display for this item type (main aspect only) ; 'rstr' kDETAspectName Contains the name of the item (attribute main aspect only) ; 'rst#' kDETAspectCategory Contains the internal categories for the record type (main aspect only) ; 'rst#' kDETAspectExternalCategory Contains the external (user-visible) names which correspond to the categories in ; kDETAspectCategory; if this resource is not present, external names are taken from ; another template; if no other template provides an external name for a given internal ; category, the internal name is used as the external name (main aspect only) ; 'rstr' kDETAspectKind Is the item kind to display (main aspect only) ; 'detn' kDETAspectGender Is the gender of this kind of object for internationalization (main aspect only) ; 'rstr' kDETAspectWhatIs Is the string for balloon help when item is in sublist (main aspect only) ; 'rstr' kDETAspectAliasKind Is the item kind to display for aliases to this type of item (main aspect only) ; 'detn' kDETAspectAliasGender Is the gender of an alias to this kind of object for internationalization (main aspect only) ; 'rstr' kDETAspectAliasWhatIs Is the string for balloon help when an alias to the item is in sublist (main aspect only) ; 'rst#' kDETAspectBalloons Is a list of strings for balloon help; for each item in an info-page, it's ; property # times 2 is used as an index into this array; if the item is not editable, ; then the property # times 2 plus 1 is used ; 'rstr' kDETAspectNewMenuName Is the string to be used for the user to select new item creation; for records, the ; string is used as a menu entry in the Catalogs menu; for attributes, the string ; is used in a selection dialog invoked by an "Add..." button ; 'rstr' kDETAspectNewEntryName Is the name to be used for new records (with a digit appended if not unique) ; 'detb' kDETAspectNewValue Is the value to use when creating a new attribute value; the first four bytes ; is the tag; the rest is the attribute value contents ; 'detn' kDETAspectSublistOpenOnNew If true (non-zero), automatically open newly created entries (property can be set ; from a code resource, or via a default value in a resource) ; 'dett' kDETAspectLookup Is the attribute-to-property translation table ; 'rstr' kDETAspectDragInString Is a string describing the action of dragging into this aspect (if any) ; 'rstr' kDETAspectDragInVerb Is a single, short word that's the verb of the action (like "add" or "drop"; if ; there's any doubt, use "OK") ; 'rstr' kDETAspectDragInSummary Is a short phrase that describes the action, suitable to be included in a selection list ; 'rst#' kDETAspectRecordDragIn Is a list of type pairs; in each pair, the first is the type of a record which ; can be dragged into this aspect, and the second is the attribute type to store ; the reference in ; 'rst#' kDETAspectRecordCatDragIn Is a list of category/attribute type pairs; in each pair, the first is the ; category of records which can be dragged in, and the second is the type of ; attribute to place the alias in ; 'rst#' kDETAspectAttrDragIn Is a list of type triples; in each triple, the first is the record type which can be ; dragged from (or "" for any), the second is the attribute type which can be dragged ; in, and the third is the attribute type to store the new attribute in ; 'rst#' kDETAspectDragOut Is a list of attribute types which can be dragged out of this aspect (an 'rst#' ; resource with no entries means nothing can be dragged out; no 'rst#' resource means ; everything can be dragged out) ; 'detm' kDETAspectViewMenu Is a table to fill in the view menu from ; 'detp' kDETAspectReverseSort Is a table listing which properties to sort in reverse order ; 'detw' kDETAspectInfoPageCustomWindow Is a specification of a custom window size/placement & whether to use the ; page-selector (main aspect only) ; 'detv' kDETAspectInfoPageCustomWindow Is a view list which is common to all info-pages (main aspect only) ; kDETAspectCode EQU 4 kDETAspectMainBitmap EQU 5 kDETAspectName EQU 6 kDETAspectCategory EQU 7 kDETAspectExternalCategory EQU 8 kDETAspectKind EQU 9 kDETAspectGender EQU 10 kDETAspectWhatIs EQU 11 kDETAspectAliasKind EQU 12 kDETAspectAliasGender EQU 13 kDETAspectAliasWhatIs EQU 14 kDETAspectBalloons EQU 15 kDETAspectNewMenuName EQU 16 kDETAspectNewEntryName EQU 17 kDETAspectNewValue EQU 18 kDETAspectSublistOpenOnNew EQU 19 kDETAspectLookup EQU 20 kDETAspectDragInString EQU 21 kDETAspectDragInVerb EQU 22 kDETAspectDragInSummary EQU 23 kDETAspectRecordDragIn EQU 24 kDETAspectRecordCatDragIn EQU 25 kDETAspectAttrDragIn EQU 26 kDETAspectAttrDragOut EQU 27 kDETAspectViewMenu EQU 28 kDETAspectReverseSort EQU 29 kDETAspectInfoPageCustomWindow EQU 30 ; Properties: kDETNoProperty EQU -1 ; Each aspect has 250 attribute properties in this range: kDETFirstLocalProperty EQU 0 kDETLastLocalProperty EQU 249 ; Developers should use property numbers starting at this point: kDETFirstDevProperty EQU 40 ; ; The following range provides constant numeric properties for use in patterns and comparisons (constant n is ; ; given by kDETFirstConstantProperty+n): ; kDETFirstConstantProperty EQU 250 kDETLastConstantProperty EQU 499 ; To convert a number into a constant property, add this: kDETConstantProperty EQU 250 kDETZeroProperty EQU 250 kDETOneProperty EQU 251 kDETFalseProperty EQU 250 kDETTrueProperty EQU 251 ; The following apply to records, attributes, or aliases; they are the name and kind, as they appear in icon lists: kDETPrName EQU 3050 kDETPrKind EQU 3051 ; Access mask properties: kDETDNodeAccessMask EQU 25825 ; The DNode access mask kDETRecordAccessMask EQU 25826 ; The record access mask kDETAttributeAccessMask EQU 25827 ; The attribute access mask kDETPrimaryMaskByBit EQU 25828 ; A set of sixteen properties to access all bits of the primary mask ; See AOCE documentation for details definitions of each of these bits: kDETPrimarySeeMask EQU 25828 kDETPrimaryAddMask EQU 25829 kDETPrimaryDeleteMask EQU 25830 kDETPrimaryChangeMask EQU 25831 kDETPrimaryRenameMask EQU 25832 kDETPrimaryChangePrivsMask EQU 25833 kDETPrimaryTopMaskBit EQU 25843 ; The following property is zero until we've completed the first catalog lookup; from then on it's 1 kDETPastFirstLookup EQU 26550 ; The following property is the page number; issuing a property command with this property will flip info-pages kDETInfoPageNumber EQU 27050 ; ; The value of the following properties contains the template number of the targeted aspect's template, and the ; currently open info-page (if any). These values can be used with kDETAspectTemplate and kDETInfoPageTemplate ; target selectors. ; kDETAspectTemplateNumber EQU 26551 kDETInfoPageTemplateNumber EQU 26552 ; Properties for property commands to deal with sublist items: kDETOpenSelectedItems EQU 26553 ; Open selected sublist items kDETAddNewItem EQU 26554 ; Add new sublist item kDETRemoveSelectedItems EQU 26555 ; Remove selected sublist items ; ; Property types are used to specify types of properties and conversions between types (zero and negative numbers ; are reserved for Apple; developer code resources can use positive numbers): ; kDETPrTypeNumber EQU -1 ; A number kDETPrTypeString EQU -2 ; A string kDETPrTypeBinary EQU -3 ; A binary block ; ************************************ Info-pages ; ; Info-pages include the following as well: ; ; Type Offset Description ; ---- ------ ----------- ; 'deti' 0 Identifies the type of resource; see below for details on the contents ; 'rstr' kDETInfoPageName Is the name of the view to use in the page selection pop-up ; 'rstr' kDETInfoPageMainViewAspect Is the name of the aspect to use with the main page view ; 'rstr' kDETInfoPageMenuName Is the name of the catalogs menu ("Catalogs" if not present) ; 'detm' kDETInfoPageMenuEntries Are menu entries to go in the Catalogs menu ; ; kDETInfoPageName EQU 4 kDETInfoPageMainViewAspect EQU 5 kDETInfoPageMenuName EQU 6 kDETInfoPageMenuEntries EQU 7 ; ; ************************************ Views ; ; Flags: ; kDETNoFlags EQU 0 ; Main view (non-sublist) field enabled kDETEnabled EQU $01 ; The following flags make sense for items in a sublist only ; Hilight view when entry is selected kDETHilightIfSelected EQU $01 ; The following flags make sense for text views only kDETNumericOnly EQU $08 ; Only allow the user to enter digits kDETMultiLine EQU $10 ; Allow multiple lines in view kDETDynamicSize EQU $0200 ; Don't draw box around text until user clicks in it, then auto-size it ; Don't allow the user to enter colons (convert ":"s to "-"s) kDETAllowNoColons EQU $0400 ; The following flags are used for pop-up menus only ; Automatically resize pop-up based on contents kDETPopupDynamicSize EQU $0100 ; The following flags are used for EditPicture views only ; Scale picture to view bounds rather than cropping kDETScaleToView EQU $0100 ; Sizes for icons kDETLargeIcon EQU 0 kDETSmallIcon EQU 1 kDETMiniIcon EQU 2 ; Stolen from TextEdit.h kDETLeft EQU 0 kDETCenter EQU 1 kDETRight EQU -1 kDETForceLeft EQU -2 ; Flags for use within Box view type attributes - these are distinct from the flags above kDETUnused EQU 0 kDETBoxTakesContentClicks EQU $01 kDETBoxIsRounded EQU $02 kDETBoxIsGrayed EQU $04 kDETBoxIsInvisible EQU $08 ; The common font info kDETApplicationFont EQU 1 kDETApplicationFontSize EQU 9 kDETAppFontLineHeight EQU 12 kDETSystemFont EQU 0 kDETSystemFontSize EQU 12 kDETSystemFontLineHeight EQU 16 kDETDefaultFont EQU 1 kDETDefaultFontSize EQU 9 kDETDefaultFontLineHeight EQU 12 ; These were taken from QuickDraw.h (where they're enums and therefore unusable in resource definitions): kDETNormal EQU 0 kDETBold EQU 1 kDETItalic EQU 2 kDETUnderline EQU 4 kDETOutline EQU 8 kDETShadow EQU $10 kDETCondense EQU $20 kDETExtend EQU $40 kDETIconStyle EQU -3 ; Normal text style for regular sublist entries, italic text style for aliases ; View menu: kDETChangeViewCommand EQU 'view' ; Change the view; used especially in StaticCommandTextFromView sublist headers ; Info-page window sizes: ; Default record info-pages: kDETRecordInfoWindHeight EQU 228 kDETRecordInfoWindWidth EQU 400 ; Default attribute info-pages: kDETAttributeInfoWindHeight EQU 250 kDETAttributeInfoWindWidth EQU 230 ; Page identifying icon (for default info-page layout): kDETSubpageIconTop EQU 8 kDETSubpageIconLeft EQU 8 kDETSubpageIconBottom EQU 40 kDETSubpageIconRight EQU 40 ; ; ************************************ Killers ; ; Killers include the following as well: ; ; Type Offset Description ; ---- ------ ----------- ; 'detk' 0 Identifies the type of resource; see below for details on the contents ; 'rst#' kDETKillerName Contains a list of template names to be killed ; ; kDETKillerName EQU 1 ; ; ************************************ Forwarders ; ; Forwarders include the following as well: ; ; Type Offset Description ; ---- ------ ----------- ; 'detf' 0 Identifies the type of resource; see below for details on the contents ; 'rst#' kDETForwarderTemplateNames Contains a list of names of templates to forward to ; ; kDETForwarderTemplateNames EQU 4 ; ********************************************************************************* ; ******************************** Code Resources: ******************************** ; ********************************************************************************* ; Target specification: kDETSelf EQU 0 ; The "current" item kDETSelfOtherAspect EQU 1 ; Another aspect of the current item kDETParent EQU 2 ; The parent (i.e., the aspect we're in the sublist of, if any) of the current item kDETSublistItem EQU 3 ; The itemNumberth item in the sublist kDETSelectedSublistItem EQU 4 ; The itemNumberth selected item in the sublist kDETDSSpec EQU 5 ; The item specified by the packed DSSpec kDETAspectTemplate EQU 6 ; A specific aspect template (number itemNumber) kDETInfoPageTemplate EQU 7 ; A specific info-page template (number itemNumber) * Force type to be short kDETHighSelector EQU $F000 ; typedef long DETTargetSelector DETTargetSpecification RECORD 0 selector ds.l 1 ; offset: $0 (0) ; Target selection method (see above) aspectName ds.l 1 ; offset: $4 (4) ; The name of the aspect (kDETSelfOtherAspect, kDETSublistItem, ; kDETSelectedSublistItem, kDETDSSpec); nil for main aspect or none; ; always filled in for calls if there is an aspect, even if it's the main aspect itemNumber ds.l 1 ; offset: $8 (8) ; Sublist index (kDETSublistItem & kDETSelectedSublistItem & kDETAspectTemplate); ; 1-based indexing dsSpec ds.l 1 ; offset: $C (12) ; DSSpec (kDETDSSpec only) sizeof EQU * ; size: $10 (16) ENDR ; ; Code resource calls and call-backs both return an OSType: ; kDETDidNotHandle (1) = used by template to say "I didn't handle it" (for calls only) ; noErr = function completed successfully ; any error = function failed, and here's why ; ; ; Call-back functions: ; ; reqFunction Action ; ----------- ------ ; kDETcmdBeep Call SysBeep; useful for testing that a code resource's calls/call-backs are working at all ; ; kDETcmdBusy Put up watch cursor and switch processes; user events elicit a beep ; ; kDETcmdChangeCallFors Change call-fors mask ; ; kDETcmdGetCommandSelectionCount Get the command selection count (for calls which have a command selection list) ; kDETcmdGetCommandItemN Get command selection item n (for calls which have a command selection list) ; ; kDETcmdOpenDSSpec PackedDSSpec open (can also be done via AppleEvents -- this is a short-cut) ; ; kDETcmdAboutToTalk About to talk to user: bring us to front, disable watch cursor, etc. ; ; kDETcmdUnloadTemplates Flush templates ; ; kDETcmdTemplateCounts Return number of aspect and info-page templates in system ; ; kDETcmdGetDSSpec Get the PackedDSSpec for this object ; ; kDETcmdSublistCount Return the count of the sublist items ; kDETcmdSelectedSublistCount Return the count of the selected sublist items ; ; kDETcmdRequestSync Request a sync-up of the aspect with the catalog ; ; kDETcmdBreakAttribute Break an attribute -- apply all applicable patterns to an attribute to generate properties ; ; kDETcmdGetTemplateFSSpec Get the FSSpec of the file containing the template ; ; kDETcmdGetOpenEdit Return the property of the view being edited (or kDETNoProperty if none) ; kDETcmdCloseEdit Close the current edit ; ; kDETcmdGetPropertyType Get a property type ; ; kDETcmdGetPropertyNumber Get a property, number format ; kDETcmdGetPropertyRString Get a property, RString format ; kDETcmdGetPropertyBinarySize Get a property, binary, return size ; kDETcmdGetPropertyBinary Get a property, binary format ; ; kDETcmdGetPropertyChanged Get a property changed flag ; kDETcmdGetPropertyEditable Get a property editable flag ; ; kDETcmdSetPropertyType Set a property type ; ; kDETcmdSetPropertyNumber Set a property, number format ; kDETcmdSetPropertyRString Set a property, RString format ; kDETcmdSetPropertyBinary Set a property, binary data & size ; ; kDETcmdSetPropertyChanged Set a property changed flag ; kDETcmdSetPropertyEditable Set a property editable flag ; ; kDETcmdDirtyProperty Dirty a property (notify other code resources of change) ; ; kDETcmdDoPropertyCommand Issue a property command ; ; kDETcmdAddMenu Add to the end of a dynamic menu ; kDETcmdRemoveMenu Remove a dynamic menu item ; kDETcmdMenuItemRString Get a dynamic menu item RString ; ; kDETcmdSaveProperty Force a save of a property -- apply all applicable patterns to write out the property ; ; kDETcmdGetCustomViewUserReference Get custom view user reference (as given in .r file) ; kDETcmdGetCustomViewBounds Get custom view current bounds ; ; kDETcmdGetResource Get a resource from a template ; kDETcmdSimpleCallback EQU 0 kDETcmdBeep EQU 1 kDETcmdBusy EQU 2 kDETcmdChangeCallFors EQU 3 kDETcmdGetCommandSelectionCount EQU 4 kDETcmdGetCommandItemN EQU 5 kDETcmdOpenDSSpec EQU 6 kDETcmdAboutToTalk EQU 7 kDETcmdUnloadTemplates EQU 8 kDETcmdTemplateCounts EQU 9 kDETcmdTargetedCallback EQU 1000 kDETcmdGetDSSpec EQU 1001 kDETcmdSublistCount EQU 1002 kDETcmdSelectedSublistCount EQU 1003 kDETcmdRequestSync EQU 1004 kDETcmdBreakAttribute EQU 1005 kDETcmdGetTemplateFSSpec EQU 1006 kDETcmdGetOpenEdit EQU 1007 kDETcmdCloseEdit EQU 1008 kDETcmdPropertyCallback EQU 2000 kDETcmdGetPropertyType EQU 2001 kDETcmdGetPropertyNumber EQU 2002 kDETcmdGetPropertyRString EQU 2003 kDETcmdGetPropertyBinarySize EQU 2004 kDETcmdGetPropertyBinary EQU 2005 kDETcmdGetPropertyChanged EQU 2006 kDETcmdGetPropertyEditable EQU 2007 kDETcmdSetPropertyType EQU 2008 kDETcmdSetPropertyNumber EQU 2009 kDETcmdSetPropertyRString EQU 2010 kDETcmdSetPropertyBinary EQU 2011 kDETcmdSetPropertyChanged EQU 2012 kDETcmdSetPropertyEditable EQU 2013 kDETcmdDirtyProperty EQU 2014 kDETcmdDoPropertyCommand EQU 2015 kDETcmdAddMenu EQU 2016 kDETcmdRemoveMenu EQU 2017 kDETcmdMenuItemRString EQU 2018 kDETcmdSaveProperty EQU 2019 kDETcmdGetCustomViewUserReference EQU 2020 kDETcmdGetCustomViewBounds EQU 2021 kDETcmdGetResource EQU 2022 ; Force type to be long kDETcmdHighCallback EQU $F0000000 ; typedef unsigned long DETCallBackFunctions ; ; Call functions: ; ; reqFunction Action ; ----------- ------ ; kDETcmdInit Called once when template is first loaded (good time to allocate private data); returns call-for list ; kDETcmdExit Called once when template is freed (good time to free private data) ; ; kDETcmdAttributeCreation New sublist attribute creation about to occur; this gives the template a chance to modify ; the value that's about to be created; sent to the template that will be used for ; the main aspect of the new entry ; ; kDETcmdDynamicForwarders Return a list of dynamically created forwarders ; ; kDETcmdInstanceInit Called once when instance of template is started (good time to allocate private instance data) ; kDETcmdInstanceExit Called once when instance is ended (good time to free private instance data) ; ; kDETcmdIdle Called periodically during idle times ; ; kDETcmdViewListChanged Called when the info-page view-list (list of enabled views) has changed ; ; kDETcmdValidateSave Validate save: about to save info-page, return noErr (or kDETDidNotHandle) if it's OK to do so ; ; kDETcmdDropQuery Drop query: return the appropriate operation for this drag; ask destination ; kDETcmdDropMeQuery Drop query: return the appropriate operation for this drag; ask dropee ; ; kDETcmdAttributeNew Attribute value new (return kDETDidNotHandle to let normal new processing occur) ; kDETcmdAttributeChange Attribute value change (return kDETDidNotHandle to let normal change processing occur) ; kDETcmdAttributeDelete Attribute value delete (return kDETDidNotHandle to let normal deletion occur); sent to the ; main aspect of the attribute that's about to be deleted ; kDETcmdItemNew Target item (record or attribute) has just been created ; ; kDETcmdOpenSelf Self open (return noErr to prevent opening; return kDETDidNotHandle to allow it) ; ; kDETcmdDynamicResource Return a dynamically created resource ; ; kDETcmdShouldSync Check if the code resource wants to force a sync (update data from catalog) ; kDETcmdDoSync Give code resource a chance to sync (read in and break all attributes) ; ; kDETcmdPropertyCommand Command received in the property number range (usually means a button's been pushed) ; ; kDETcmdMaximumTextLength Return maximum size for text form of property ; ; kDETcmdPropertyDirtied Property dirtied, need to redraw ; ; kDETcmdPatternIn Custom pattern element encountered on reading in an attribute ; kDETcmdPatternOut Custom pattern element encountered on writing out an attribute ; ; kDETcmdConvertToNumber Convert from template-defined property type to number ; kDETcmdConvertToRString Convert from template-defined property type to RString ; kDETcmdConvertFromNumber Convert from number to template-defined property type ; kDETcmdConvertFromRString Convert from RString to template-defined property type ; ; kDETcmdCustomViewDraw Custom view draw ; kDETcmdCustomViewMouseDown Custom view mouse down ; ; kDETcmdKeyPress Key press (used primarily to filter entry into EditText views) ; kDETcmdPaste Paste (used primarily to filter entry into EditText views) ; ; kDETcmdCustomMenuSelected Custom Catalogs menu selected ; kDETcmdCustomMenuEnabled Return whether custom Catalogs menu entry should be enabled ; kDETcmdSimpleCall EQU 0 kDETcmdInit EQU 1 kDETcmdExit EQU 2 kDETcmdAttributeCreation EQU 3 kDETcmdDynamicForwarders EQU 4 kDETcmdTargetedCall EQU 1000 kDETcmdInstanceInit EQU 1001 kDETcmdInstanceExit EQU 1002 kDETcmdIdle EQU 1003 kDETcmdViewListChanged EQU 1004 kDETcmdValidateSave EQU 1005 kDETcmdDropQuery EQU 1006 kDETcmdDropMeQuery EQU 1007 kDETcmdAttributeNew EQU 1008 kDETcmdAttributeChange EQU 1009 kDETcmdAttributeDelete EQU 1010 kDETcmdItemNew EQU 1011 kDETcmdOpenSelf EQU 1012 kDETcmdDynamicResource EQU 1013 kDETcmdShouldSync EQU 1014 kDETcmdDoSync EQU 1015 kDETcmdPropertyCall EQU 2000 kDETcmdPropertyCommand EQU 2001 kDETcmdMaximumTextLength EQU 2002 kDETcmdPropertyDirtied EQU 2003 kDETcmdPatternIn EQU 2004 kDETcmdPatternOut EQU 2005 kDETcmdConvertToNumber EQU 2006 kDETcmdConvertToRString EQU 2007 kDETcmdConvertFromNumber EQU 2008 kDETcmdConvertFromRString EQU 2009 kDETcmdCustomViewDraw EQU 2010 kDETcmdCustomViewMouseDown EQU 2011 kDETcmdKeyPress EQU 2012 kDETcmdPaste EQU 2013 kDETcmdCustomMenuSelected EQU 2014 kDETcmdCustomMenuEnabled EQU 2015 kDETcmdHighCall EQU $F0000000 ; Force the type to be long ; typedef unsigned long DETCallFunctions ; Valid commandIDs for DETDropQueryBlock and DETDropMeQueryBlock (in addition to property numbers): kDETDoNothing EQU 'xxx0' kDETMove EQU 'move' kDETDrag EQU 'drag' kDETAlias EQU 'alis' DETProtoCallBackBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to sizeof EQU * ; size: $16 (22) ENDR DETBeepBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function sizeof EQU * ; size: $4 (4) ENDR DETBusyBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function sizeof EQU * ; size: $4 (4) ENDR DETChangeCallForsBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request newCallFors ds.l 1 ; offset: $14 (20) ; -> New call-for mask sizeof EQU * ; size: $18 (24) ENDR DETGetCommandSelectionCountBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function count ds.l 1 ; offset: $4 (4) ; <- The number of items in the command selection list sizeof EQU * ; size: $8 (8) ENDR kDETHFSType EQU 0 ; HFS item type kDETDSType EQU 1 ; Catalog Service item type kDETMailType EQU 2 ; Mail (letter) item type kDETMoverType EQU 3 ; Sounds, fonts, etc., from inside a suitcase or system file kDETLastItemType EQU $F0000000 ; Force it to be a long (C & C++ seem to disagree about the definition of 0xF000) ; typedef unsigned long DETItemType ; FSSpec plus possibly interesting additional info DETFSInfo RECORD 0 fileType ds.l 1 ; offset: $0 (0) ; File type fileCreator ds.l 1 ; offset: $4 (4) ; File creator fdFlags ds.w 1 ; offset: $8 (8) ; Finder flags fsSpec ds FSSpec ; offset: $A (10) ; FSSpec sizeof EQU * ; size: $50 (80) ENDR DSRec RECORD 0 dsSpec ds.l 1 ; offset: $0 (0) ; <- DSSpec for item (caller must DisposHandle() when done) refNum ds.w 1 ; offset: $4 (4) ; <- Refnum for returned address identity ds.l 1 ; offset: $6 (6) ; <- Identity for returned address sizeof EQU * ; size: $A (10) ENDR ItemRec RECORD 0 fsInfo ds.l 1 ; offset: $0 (0) ; <- FSSpec & info for item (caller must DisposHandle() when done) ORG 0 ds ds DSRec ; offset: $0 (0) ORG 0 dsSpec ds.l 1 ; offset: $0 (0) ; <- DSSpec for item (caller must DisposHandle() when done) ORG 0 ltrSpec ds.l 1 ; offset: $0 (0) ; <- Letter spec for item (caller must DisposHandle() when done) ORG 10 sizeof EQU * ; size: $A (10) ENDR DETGetCommandItemNBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function itemNumber ds.l 1 ; offset: $4 (4) ; -> Item number to retrieve (1-based) itemType ds.l 1 ; offset: $8 (8) ; -> Type of item to be returned (if we can interpret it as such) item ds ItemRec ; offset: $C (12) sizeof EQU * ; size: $16 (22) ENDR DETGetDSSpecBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request dsSpec ds.l 1 ; offset: $14 (20) ; <- Handle with result (caller must DisposHandle() when done) refNum ds.w 1 ; offset: $18 (24) ; <- Refnum for address if PD identity ds.l 1 ; offset: $1A (26) ; <- Identity for address isAlias ds.b 1 ; offset: $1E (30) ; <- True if this entry is an alias isRecordRef ds.b 1 ; offset: $1F (31) ; <- True if this entry is a record reference (reserved) sizeof EQU * ; size: $20 (32) ENDR DETGetTemplateFSSpecBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request fsSpec ds FSSpec ; offset: $14 (20) ; <- FSSpec of template file baseID ds.w 1 ; offset: $5A (90) ; <- Base ID of this template aspectTemplateNumber ds.l 1 ; offset: $5C (92) ; <- The template number for this aspect template sizeof EQU * ; size: $60 (96) ENDR DETGetOpenEditBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request viewProperty ds.w 1 ; offset: $14 (20) ; <- The property of the view being edited (or kNoProperty if none) sizeof EQU * ; size: $16 (22) ENDR DETCloseEditBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request sizeof EQU * ; size: $14 (20) ENDR DETGetPropertyTypeBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyType ds.w 1 ; offset: $16 (22) ; <- The type of the property sizeof EQU * ; size: $18 (24) ENDR DETGetPropertyNumberBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyValue ds.l 1 ; offset: $16 (22) ; <- The value of the property sizeof EQU * ; size: $1A (26) ENDR DETGetPropertyRStringBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyValue ds.l 1 ; offset: $16 (22) ; <- A handle containing the property (as an RString) (caller must DisposHandle() when done) sizeof EQU * ; size: $1A (26) ENDR DETGetPropertyBinarySizeBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyBinarySize ds.l 1 ; offset: $16 (22) ; <- The size of the property as a binary block sizeof EQU * ; size: $1A (26) ENDR DETGetPropertyBinaryBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyValue ds.l 1 ; offset: $16 (22) ; <- Handle with the value of the property (caller must DisposHandle() when done) sizeof EQU * ; size: $1A (26) ENDR DETGetPropertyChangedBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyChanged ds.b 1 ; offset: $16 (22) ; <- True if the property is marked as changed filler1 ds.b 1 ; offset: $17 (23) sizeof EQU * ; size: $18 (24) ENDR DETGetPropertyEditableBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyEditable ds.b 1 ; offset: $16 (22) ; <- True if the property can be edited by the user (if false, view will appear disabled) filler1 ds.b 1 ; offset: $17 (23) sizeof EQU * ; size: $18 (24) ENDR DETSetPropertyTypeBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to newType ds.w 1 ; offset: $16 (22) ; -> New type for property (just sets type, does not convert contents) sizeof EQU * ; size: $18 (24) ENDR DETSetPropertyNumberBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to newValue ds.l 1 ; offset: $16 (22) ; -> New value to set property to (and set type to number) sizeof EQU * ; size: $1A (26) ENDR DETSetPropertyRStringBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to newValue ds.l 1 ; offset: $16 (22) ; -> New value to set property to (and set type to RString) sizeof EQU * ; size: $1A (26) ENDR DETSetPropertyBinaryBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to newValue ds.l 1 ; offset: $16 (22) ; -> New value to set property to (and set type to binary) newValueSize ds.l 1 ; offset: $1A (26) ; -> Size of new value sizeof EQU * ; size: $1E (30) ENDR DETSetPropertyChangedBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyChanged ds.b 1 ; offset: $16 (22) ; -> Value to set changed flag on property to filler1 ds.b 1 ; offset: $17 (23) sizeof EQU * ; size: $18 (24) ENDR DETSetPropertyEditableBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to propertyEditable ds.b 1 ; offset: $16 (22) ; -> Value to set editable flag on property to filler1 ds.b 1 ; offset: $17 (23) sizeof EQU * ; size: $18 (24) ENDR DETDirtyPropertyBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to sizeof EQU * ; size: $16 (22) ENDR DETDoPropertyCommandBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to parameter ds.l 1 ; offset: $16 (22) ; -> Parameter of command sizeof EQU * ; size: $1A (26) ENDR DETSublistCountBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request count ds.l 1 ; offset: $14 (20) ; <- The number of items in the current item's sublist sizeof EQU * ; size: $18 (24) ENDR DETSelectedSublistCountBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request count ds.l 1 ; offset: $14 (20) ; <- The number of selected items in the current item's sublist sizeof EQU * ; size: $18 (24) ENDR DETRequestSyncBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request sizeof EQU * ; size: $14 (20) ENDR DETAddMenuBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to name ds.l 1 ; offset: $16 (22) ; -> Name of new menu item parameter ds.l 1 ; offset: $1A (26) ; -> Parameter to return when this item is selected addAfter ds.l 1 ; offset: $1E (30) ; -> Parameter of entry to add after, or -1 for add at end sizeof EQU * ; size: $22 (34) ENDR DETRemoveMenuBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to itemToRemove ds.l 1 ; offset: $16 (22) ; -> Parameter of menu item to remove sizeof EQU * ; size: $1A (26) ENDR DETMenuItemRStringBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to itemParameter ds.l 1 ; offset: $16 (22) ; -> Parameter of menu item to return string for rString ds.l 1 ; offset: $1A (26) ; <- Handle with the RString (caller must DisposHandle() when done) sizeof EQU * ; size: $1E (30) ENDR DETOpenDSSpecBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function dsSpec ds.l 1 ; offset: $4 (4) ; -> DSSpec of object to be opened sizeof EQU * ; size: $8 (8) ENDR DETAboutToTalkBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function sizeof EQU * ; size: $4 (4) ENDR DETBreakAttributeBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request breakAttribute ds.l 1 ; offset: $14 (20) ; -> Attribute to parse isChangeable ds.b 1 ; offset: $18 (24) ; -> True if the value can be changed by the user filler1 ds.b 1 ; offset: $19 (25) sizeof EQU * ; size: $1A (26) ENDR DETSavePropertyBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to sizeof EQU * ; size: $16 (22) ENDR DETGetCustomViewUserReferenceBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to userReference ds.w 1 ; offset: $16 (22) ; <- User reference value, as specified in the .r file sizeof EQU * ; size: $18 (24) ENDR DETGetCustomViewBoundsBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to bounds ds Rect ; offset: $16 (22) ; <- Bounds of the view sizeof EQU * ; size: $1E (30) ENDR DETGetResourceBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function target ds DETTargetSpecification ; offset: $4 (4) ; The target for the request property ds.w 1 ; offset: $14 (20) ; The property to apply the request to resourceType ds.l 1 ; offset: $16 (22) ; -> Resource type theResource ds.l 1 ; offset: $1A (26) ; <- The resource handle (caller must dispose when done) sizeof EQU * ; size: $1E (30) ENDR DETTemplateCounts RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function aspectTemplateCount ds.l 1 ; offset: $4 (4) ; <- Number of aspect templates in the system infoPageTemplateCount ds.l 1 ; offset: $8 (8) ; <- Number of info-page templates in the system sizeof EQU * ; size: $C (12) ENDR DETUnloadTemplatesBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function sizeof EQU * ; size: $4 (4) ENDR DETCallBackBlock RECORD 0 protoCallBack ds DETProtoCallBackBlock ; offset: $0 (0) ORG 0 beep ds DETBeepBlock ; offset: $0 (0) ORG 0 busy ds DETBusyBlock ; offset: $0 (0) ORG 0 changeCallFors ds DETChangeCallForsBlock ; offset: $0 (0) ORG 0 getCommandSelectionCount ds DETGetCommandSelectionCountBlock ; offset: $0 (0) ORG 0 getCommandItemN ds DETGetCommandItemNBlock ; offset: $0 (0) ORG 0 getDSSpec ds DETGetDSSpecBlock ; offset: $0 (0) ORG 0 getTemplateFSSpec ds DETGetTemplateFSSpecBlock ; offset: $0 (0) ORG 0 getOpenEdit ds DETGetOpenEditBlock ; offset: $0 (0) ORG 0 closeEdit ds DETCloseEditBlock ; offset: $0 (0) ORG 0 getPropertyType ds DETGetPropertyTypeBlock ; offset: $0 (0) ORG 0 getPropertyNumber ds DETGetPropertyNumberBlock ; offset: $0 (0) ORG 0 getPropertyRString ds DETGetPropertyRStringBlock ; offset: $0 (0) ORG 0 getPropertyBinarySize ds DETGetPropertyBinarySizeBlock ; offset: $0 (0) ORG 0 getPropertyBinary ds DETGetPropertyBinaryBlock ; offset: $0 (0) ORG 0 getPropertyChanged ds DETGetPropertyChangedBlock ; offset: $0 (0) ORG 0 getPropertyEditable ds DETGetPropertyEditableBlock ; offset: $0 (0) ORG 0 setPropertyType ds DETSetPropertyTypeBlock ; offset: $0 (0) ORG 0 setPropertyNumber ds DETSetPropertyNumberBlock ; offset: $0 (0) ORG 0 setPropertyRString ds DETSetPropertyRStringBlock ; offset: $0 (0) ORG 0 setPropertyBinary ds DETSetPropertyBinaryBlock ; offset: $0 (0) ORG 0 setPropertyChanged ds DETSetPropertyChangedBlock ; offset: $0 (0) ORG 0 setPropertyEditable ds DETSetPropertyEditableBlock ; offset: $0 (0) ORG 0 dirtyProperty ds DETDirtyPropertyBlock ; offset: $0 (0) ORG 0 doPropertyCommand ds DETDoPropertyCommandBlock ; offset: $0 (0) ORG 0 sublistCount ds DETSublistCountBlock ; offset: $0 (0) ORG 0 selectedSublistCount ds DETSelectedSublistCountBlock ; offset: $0 (0) ORG 0 requestSync ds DETRequestSyncBlock ; offset: $0 (0) ORG 0 addMenu ds DETAddMenuBlock ; offset: $0 (0) ORG 0 removeMenu ds DETRemoveMenuBlock ; offset: $0 (0) ORG 0 menuItemRString ds DETMenuItemRStringBlock ; offset: $0 (0) ORG 0 openDSSpec ds DETOpenDSSpecBlock ; offset: $0 (0) ORG 0 aboutToTalk ds DETAboutToTalkBlock ; offset: $0 (0) ORG 0 breakAttribute ds DETBreakAttributeBlock ; offset: $0 (0) ORG 0 saveProperty ds DETSavePropertyBlock ; offset: $0 (0) ORG 0 getCustomViewUserReference ds DETGetCustomViewUserReferenceBlock ; offset: $0 (0) ORG 0 getCustomViewBounds ds DETGetCustomViewBoundsBlock ; offset: $0 (0) ORG 0 getResource ds DETGetResourceBlock ; offset: $0 (0) ORG 0 templateCounts ds DETTemplateCounts ; offset: $0 (0) ORG 0 unloadTemplates ds DETUnloadTemplatesBlock ; offset: $0 (0) ORG 96 sizeof EQU * ; size: $60 (96) ENDR ; typedef union DETCallBackBlock * DETCallBackBlockPtr ; typedef DETCallBlock * DETCallBlockPtr ; typedef DETCallBackUPP DETCallBack DETProtoCallBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to sizeof EQU * ; size: $28 (40) ENDR DETInitBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, common to all invocations of code resource) newCallFors ds.l 1 ; offset: $10 (16) ; <- New call-for mask sizeof EQU * ; size: $14 (20) ENDR DETExitBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, common to all invocations of code resource) sizeof EQU * ; size: $10 (16) ENDR DETInstanceInitBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETInstanceExitBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETInstanceIdleBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETPropertyCommandBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to parameter ds.l 1 ; offset: $28 (40) ; -> Parameter of command sizeof EQU * ; size: $2C (44) ENDR DETMaximumTextLengthBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to maxSize ds.l 1 ; offset: $28 (40) ; <- Return the maximum number of characters the user can entry when property is edited in an EditText sizeof EQU * ; size: $2C (44) ENDR DETViewListChangedBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETPropertyDirtiedBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to sizeof EQU * ; size: $28 (40) ENDR DETValidateSaveBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) errorString ds.l 1 ; offset: $26 (38) ; <- Handle with error string if validation fails (callee must allocate handle, DE will DisposHandle() it) sizeof EQU * ; size: $2A (42) ENDR DETDropQueryBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) modifiers ds.w 1 ; offset: $26 (38) ; -> Modifiers at drop time (option/control/command/shift keys) commandID ds.l 1 ; offset: $28 (40) ; <-> Command ID (kDETDoNothing, kDETMove, kDETDrag (copy), kDETAlias, or a property number) destinationType ds AttributeType ; offset: $2C (44) ; <-> Type to convert attribute to copyToHFS ds.b 1 ; offset: $50 (80) ; <- If true, object should be copied to HFS before being operated on, and deleted after filler2 ds.b 1 ; offset: $51 (81) sizeof EQU * ; size: $52 (82) ENDR DETDropMeQueryBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) modifiers ds.w 1 ; offset: $26 (38) ; -> Modifiers at drop time (option/control/command/shift keys) commandID ds.l 1 ; offset: $28 (40) ; <-> Command ID (kDETDoNothing, kDETMove, kDETDrag (copy), kDETAlias, or a property number) destinationType ds AttributeType ; offset: $2C (44) ; <-> Type to convert attribute to copyToHFS ds.b 1 ; offset: $50 (80) ; <- If true, object should be copied to HFS before being operated on, and deleted after filler2 ds.b 1 ; offset: $51 (81) sizeof EQU * ; size: $52 (82) ENDR DETAttributeCreationBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, common to all invocations of code resource) parent ds.l 1 ; offset: $10 (16) ; -> The object within which the creation will occur refNum ds.w 1 ; offset: $14 (20) ; -> Refnum for returned address (DSSpecs in PDs only) identity ds.l 1 ; offset: $16 (22) ; -> The identity we're browsing as in the parent object attrType ds AttributeType ; offset: $1A (26) ; <-> The type of the attribute being created attrTag ds.l 1 ; offset: $3E (62) ; <-> The tag of the attribute being created value ds.l 1 ; offset: $42 (66) ; <-> The value to write (pre-allocated, resize as needed) sizeof EQU * ; size: $46 (70) ENDR DETAttributeNewBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) parent ds.l 1 ; offset: $26 (38) ; -> The object within which the creation will occur refNum ds.w 1 ; offset: $2A (42) ; -> Refnum for returned address (DSSpecs in PDs only) identity ds.l 1 ; offset: $2C (44) ; -> The identity we're browsing as in the parent object attrType ds AttributeType ; offset: $30 (48) ; <-> The type of the attribute being created attrTag ds.l 1 ; offset: $54 (84) ; <-> The tag of the attribute being created value ds.l 1 ; offset: $58 (88) ; <-> The value to write (pre-allocated, resize as needed) sizeof EQU * ; size: $5C (92) ENDR DETAttributeChangeBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) parent ds.l 1 ; offset: $26 (38) ; -> The object within which the creation will occur refNum ds.w 1 ; offset: $2A (42) ; -> Refnum for returned address (DSSpecs in PDs only) identity ds.l 1 ; offset: $2C (44) ; -> The identity we're browsing as in the parent object attrType ds AttributeType ; offset: $30 (48) ; <-> The type of the attribute being changed attrTag ds.l 1 ; offset: $54 (84) ; <-> The tag of the attribute being changed attrCID ds AttributeCreationID ; offset: $58 (88) ; <-> The CID of the attribute being changed value ds.l 1 ; offset: $60 (96) ; <-> The value to write (pre-allocated, resize as needed) sizeof EQU * ; size: $64 (100) ENDR DETAttributeDeleteBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) dsSpec ds.l 1 ; offset: $26 (38) ; -> The object which will be deleted refNum ds.w 1 ; offset: $2A (42) ; -> Refnum for returned address (DSSpecs in PDs only) identity ds.l 1 ; offset: $2C (44) ; -> The identity we're browsing as sizeof EQU * ; size: $30 (48) ENDR DETItemNewBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETShouldSyncBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) shouldSync ds.b 1 ; offset: $26 (38) ; <- True if we should now sync with catalog filler2 ds.b 1 ; offset: $27 (39) sizeof EQU * ; size: $28 (40) ENDR DETDoSyncBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) sizeof EQU * ; size: $26 (38) ENDR DETPatternInBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to elementType ds.l 1 ; offset: $28 (40) ; -> Element type from pattern extra ds.l 1 ; offset: $2C (44) ; -> Extra field from pattern attribute ds.l 1 ; offset: $30 (48) ; -> The complete attribute dataOffset ds.l 1 ; offset: $34 (52) ; <-> Offset to current (next) byte bitOffset ds.w 1 ; offset: $38 (56) ; <-> Bit offset (next bit is *fData >> fBitOffset++) sizeof EQU * ; size: $3A (58) ENDR DETPatternOutBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to elementType ds.l 1 ; offset: $28 (40) ; -> Element type from pattern extra ds.l 1 ; offset: $2C (44) ; -> Extra field from pattern attribute ds.l 1 ; offset: $30 (48) ; -> The attribute (minus the data portion) data ds.l 1 ; offset: $34 (52) ; -> Data to be written (pre-allocated, resize and add at end) dataOffset ds.l 1 ; offset: $38 (56) ; <-> Offset to next byte to write bitOffset ds.w 1 ; offset: $3C (60) ; <-> Bit offset (if zero, handle will need to be resized to one more byte before write) sizeof EQU * ; size: $3E (62) ENDR DETOpenSelfBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) modifiers ds.w 1 ; offset: $26 (38) ; -> Modifiers at open time (option/control/command/shift keys) sizeof EQU * ; size: $28 (40) ENDR DETConvertToNumberBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theValue ds.l 1 ; offset: $28 (40) ; <- The converted value to return sizeof EQU * ; size: $2C (44) ENDR DETConvertToRStringBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theValue ds.l 1 ; offset: $28 (40) ; <- A handle with the converted value (callee must allocate handle, DE will DisposHandle() it) sizeof EQU * ; size: $2C (44) ENDR DETConvertFromNumberBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theValue ds.l 1 ; offset: $28 (40) ; -> The value to convert (result should be written direct to the property) sizeof EQU * ; size: $2C (44) ENDR DETConvertFromRStringBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theValue ds.l 1 ; offset: $28 (40) ; -> The value to convert (result should be written direct to the property) sizeof EQU * ; size: $2C (44) ENDR DETCustomViewDrawBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to sizeof EQU * ; size: $28 (40) ENDR DETCustomViewMouseDownBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theEvent ds.l 1 ; offset: $28 (40) ; -> The original event record of the mouse-down sizeof EQU * ; size: $2C (44) ENDR DETKeyPressBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to theEvent ds.l 1 ; offset: $28 (40) ; -> The original event record of the key-press sizeof EQU * ; size: $2C (44) ENDR DETPasteBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) property ds.w 1 ; offset: $26 (38) ; The property number the call refers to modifiers ds.w 1 ; offset: $28 (40) ; -> Modifiers at paste time (option/control/command/shift keys) sizeof EQU * ; size: $2A (42) ENDR DETCustomMenuSelectedBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) menuTableParameter ds.w 1 ; offset: $26 (38) ; -> The "property" field from the custom menu table sizeof EQU * ; size: $28 (40) ENDR DETCustomMenuEnabledBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) menuTableParameter ds.w 1 ; offset: $26 (38) ; -> The "property" field from the custom menu table enable ds.b 1 ; offset: $28 (40) ; <- Whether to enable the menu item filler2 ds.b 1 ; offset: $29 (41) sizeof EQU * ; size: $2A (42) ENDR DETForwarderListItem RECORD 0 next ds.l 1 ; offset: $0 (0) ; Pointer to next item, or nil attributeValueTag ds.l 1 ; offset: $4 (4) ; Tag of new templates (0 for none) rstrs ds PackedPathName ; offset: $8 (8) ; Record type (empty if none), attrbute type (empty if none),list of template names to forward to sizeof EQU * ; size: $408 (1032) ENDR ; typedef struct DETForwarderListItem * DETForwarderListPtr ; typedef DETForwarderListPtr * DETForwarderListHandle DETDynamicForwardersBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, common to all invocations of code resource) forwarders ds.l 1 ; offset: $10 (16) ; <- List of forwaders sizeof EQU * ; size: $14 (20) ENDR DETDynamicResourceBlock RECORD 0 reqFunction ds.l 1 ; offset: $0 (0) ; Requested function callBack ds.l 1 ; offset: $4 (4) ; Pointer to call-back routine callBackPrivate ds.l 1 ; offset: $8 (8) ; Private data for the call-back routine templatePrivate ds.l 1 ; offset: $C (12) ; Private storage for use by code resource (stays for life of code resource, ; common to all invocations of code resource) instancePrivate ds.l 1 ; offset: $10 (16) ; Private storage for use by code resource (separate for each item using the ; code resource) target ds DETTargetSpecification ; offset: $14 (20) ; The target (originator) of the call, for targeted and property calls targetIsMainAspect ds.b 1 ; offset: $24 (36) ; True if the target is the main aspect (even though it has a non-nil name) filler1 ds.b 1 ; offset: $25 (37) resourceType ds.l 1 ; offset: $26 (38) ; -> The resource type being requested propertyNumber ds.w 1 ; offset: $2A (42) ; -> The property number of the resource being requested resourceID ds.w 1 ; offset: $2C (44) ; -> The resource ID (base ID + property number) of the resource theResource ds.l 1 ; offset: $2E (46) ; <- The requested resource sizeof EQU * ; size: $32 (50) ENDR DETCallBlock RECORD 0 protoCall ds DETProtoCallBlock ; offset: $0 (0) ORG 0 init ds DETInitBlock ; offset: $0 (0) ORG 0 exit ds DETExitBlock ; offset: $0 (0) ORG 0 instanceInit ds DETInstanceInitBlock ; offset: $0 (0) ORG 0 instanceExit ds DETInstanceExitBlock ; offset: $0 (0) ORG 0 instanceIdle ds DETInstanceIdleBlock ; offset: $0 (0) ORG 0 propertyCommand ds DETPropertyCommandBlock ; offset: $0 (0) ORG 0 maximumTextLength ds DETMaximumTextLengthBlock ; offset: $0 (0) ORG 0 viewListChanged ds DETViewListChangedBlock ; offset: $0 (0) ORG 0 propertyDirtied ds DETPropertyDirtiedBlock ; offset: $0 (0) ORG 0 validateSave ds DETValidateSaveBlock ; offset: $0 (0) ORG 0 dropQuery ds DETDropQueryBlock ; offset: $0 (0) ORG 0 dropMeQuery ds DETDropMeQueryBlock ; offset: $0 (0) ORG 0 attributeCreationBlock ds DETAttributeCreationBlock ; offset: $0 (0) ORG 0 attributeNew ds DETAttributeNewBlock ; offset: $0 (0) ORG 0 attributeChange ds DETAttributeChangeBlock ; offset: $0 (0) ORG 0 attributeDelete ds DETAttributeDeleteBlock ; offset: $0 (0) ORG 0 itemNew ds DETItemNewBlock ; offset: $0 (0) ORG 0 patternIn ds DETPatternInBlock ; offset: $0 (0) ORG 0 patternOut ds DETPatternOutBlock ; offset: $0 (0) ORG 0 shouldSync ds DETShouldSyncBlock ; offset: $0 (0) ORG 0 doSync ds DETDoSyncBlock ; offset: $0 (0) ORG 0 openSelf ds DETOpenSelfBlock ; offset: $0 (0) ORG 0 convertToNumber ds DETConvertToNumberBlock ; offset: $0 (0) ORG 0 convertToRString ds DETConvertToRStringBlock ; offset: $0 (0) ORG 0 convertFromNumber ds DETConvertFromNumberBlock ; offset: $0 (0) ORG 0 convertFromRString ds DETConvertFromRStringBlock ; offset: $0 (0) ORG 0 customViewDraw ds DETCustomViewDrawBlock ; offset: $0 (0) ORG 0 customViewMouseDown ds DETCustomViewMouseDownBlock ; offset: $0 (0) ORG 0 keyPress ds DETKeyPressBlock ; offset: $0 (0) ORG 0 paste ds DETPasteBlock ; offset: $0 (0) ORG 0 customMenuSelected ds DETCustomMenuSelectedBlock ; offset: $0 (0) ORG 0 customMenuEnabled ds DETCustomMenuEnabledBlock ; offset: $0 (0) ORG 0 dynamicForwarders ds DETDynamicForwardersBlock ; offset: $0 (0) ORG 0 dynamicResource ds DETDynamicResourceBlock ; offset: $0 (0) ORG 100 sizeof EQU * ; size: $64 (100) ENDR ; Call-for list: kDETCallForOther EQU 1 ; Call for things not listed below (also auto-enabled by DE if any of the below are enabled) kDETCallForIdle EQU 2 ; kDETcmdIdle kDETCallForCommands EQU 4 ; kDETcmdPropertyCommand, kDETcmdSelfOpen kDETCallForViewChanges EQU 8 ; kDETcmdViewListChanged, kDETcmdPropertyDirtied, kDETcmdMaximumTextLength kDETCallForDrops EQU $10 ; kDETcmdDropQuery, kDETcmdDropMeQuery kDETCallForAttributes EQU $20 ; kDETcmdAttributeCreation, kDETcmdAttributeNew, kDETcmdAttributeChange, kDETcmdAttributeDelete kDETCallForValidation EQU $40 ; kDETcmdValidateSave kDETCallForKeyPresses EQU $80 ; kDETcmdKeyPress and kDETcmdPaste kDETCallForResources EQU $0100 ; kDETcmdDynamicResource kDETCallForSyncing EQU $0200 ; kDETcmdShouldSync, kDETcmdDoSync kDETCallForEscalation EQU $8000 ; All calls escalated from the next lower level kDETCallForNothing EQU 0 ; None of the above kDETCallForEverything EQU $FFFFFFFF ; All of the above ; typedef DETCallUPP DETCall ; This following macro saves you from having to dig out the call-back pointer from the call block: ; ********************************************************************************** ; ******************************** SAM Definitions: ******************************** ; ********************************************************************************** ; SAM Developers should use property numbers starting at this point: kSAMFirstDevProperty EQU 50 ; ; SAM templates have additional resources/properties that are required ; for interaction with the AOCE Key Chain. ; ; Type Offset Description ; ---- ------ ----------- ; 'rstr' kSAMAspectUserName The user name ; 'rstr' kSAMAspectKind The kind of SAM ; 'detn' kSAMAspectCannotDelete If 0, then the slot cannot be deleted ; 'sami' kSAMAspectSlotCreationInfo The info required to create a slot record ; kSAMAspectUserName EQU 41 kSAMAspectKind EQU 42 kSAMAspectCannotDelete EQU 43 kSAMAspectSlotCreationInfo EQU 44 ; ;************************************************************************************* ; ********************************* Admin Definitions: ********************************* ; ************************************************************************************* ; kDETAdminVersion EQU -978 ENDIF ENDIF ; __OCETEMPLATES__